<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
	<meta http-equiv="Expires" content="-1">

    <title>Multi Payment Apps - Madrasah Diniyah El-Bayan</title>

    <link href="<?php echo base_url()?>content/theme/css/bootstrap.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/css/bootstrap-switch.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/css/normalize.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/css/zurb/foundation.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/css/zurb/normalize.css" rel="stylesheet">
	  <link href="<?php echo base_url()?>content/theme/font-awesome/css/font-awesome.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/css/elbayan.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/css/plugins/datepicker/dp3.css" rel="stylesheet">
    <link href="<?php echo base_url()?>content/theme/js/plugins/modal/jquery.modal.css" rel="stylesheet">

	  <link rel="shortcut icon" href="<?php echo base_url()?>content/theme/images/elba.png">
	
	  <script src="<?php echo base_url()?>content/theme/js/plugins/zurb/vendor/jquery.js"></script>
    <script src="<?php echo base_url()?>content/theme/js/plugins/datepicker/bootstrap-datepicker.js"></script>
    <script src="<?php echo base_url()?>content/theme/js/plugins/datepicker/bootstrap-datepicker.id.js"></script>
	
	  <script>
    //set timezone
    // <?php date_default_timezone_set('Asia/Jakarta'); ?>
    //buat object date berdasarkan waktu di server
    // var serverTime = new Date(<?php print date('Y, m, d, H, i, s, 0'); ?>);
    //buat object date berdasarkan waktu di client
    // var clientTime = new Date();
    //hitung selisih
    // var Diff = serverTime.getTime() - clientTime.getTime();    
    //fungsi displayTime yang dipanggil di bodyOnLoad dieksekusi tiap 1000ms = 1detik
    // function displayServerTime(){
        //buat object date berdasarkan waktu di client
        // var clientTime = new Date();
        //buat object date dengan menghitung selisih waktu client dan server
        // var time = new Date(clientTime.getTime() + Diff);
        //ambil nilai jam
        // var sh = time.getHours().toString();
        //ambil nilai menit
        // var sm = time.getMinutes().toString();
        //ambil nilai detik
        // var ss = time.getSeconds().toString();
        //tampilkan jam:menit:detik dengan menambahkan angka 0 jika angkanya cuma satu digit (0-9)
        // document.getElementById("clock").innerHTML = (sh.length==1?"0"+sh:sh) + ":" + (sm.length==1?"0"+sm:sm) + ":" + (ss.length==1?"0"+ss:ss);
    }
	</script>
</head>

<body onload="setInterval('displayServerTime()', 1000);">
<!-- Preloader -->
<div id="preloader">
    <div id="status">
		<div class="spinner"></div>
	</div>
</div>


<div id="bungkus">

	<nav class="navbar navbar-default navbar-fixed-top navatas" role="navigation">
		<div class="container-fluid">
			<!-- Brand and toggle get grouped for better mobile display -->
			<div class="navbar-header">
				<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
					<span class="sr-only">Toggle navigation</span>
					<span class="icon-bar"></span>
					<span class="icon-bar"></span>
					<span class="icon-bar"></span>
				</button>
				<a class="navbar-brand brand-logo" href="<?php echo site_url()?>"><img src="<?php echo base_url()?>content/theme/images/logo.png" /></a>
			</div>
			<div class="cur_menu">
			<?php if (!empty($judul)){echo $judul;}else{echo "Judul belum diatur";} ?>
			</div>
			<!-- <div class="header-kanan">
			<p class="nama-login"><?php //echo $nama; ?> Agus Nurfatony</p>
			<p class="sebagai"><?php //echo $level; ?> Administrator <a href="<?php echo base_url()?>masuk/logOut">[Keluar]</a></p>
			<span class="nama"><span id="clock"><?php print date('H:i:s'); ?></span> WIB</span>
			<p class="a"><?php echo hijriah(explode(",",date ("w,d,n,Y",strtotime(date("Y-m-d"))))); ?></p>
			</div> -->
	  </div>
	</nav>
<?php
$_SERVER['REQUEST_URI_PATH'] = parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH);
$segments = explode('/', $_SERVER['REQUEST_URI_PATH']);

$char = substr($segments[2],0,1);
$charSDM = substr($segments[2],0,5);
?>	
<nav class="navbar-default navbar-static-side navkiri bghitam" role="navigation">
  <div class="sidebar-collapse">
    <ul class="nav" id="side-menu">
      
      <li><a href='<?php echo site_url();?>dashboard'><i class="fa fa-tasks fa-fw"></i> Dashboard</a></li>
      <li class="<?php if ($char =="m" && $charSDM <>"m_tho" && $charSDM <>"m_peg"){echo "active";}else{echo "";}?>"><a><i class="fa fa-hdd-o fa-fw"></i> Master<span class='fa arrow'></span></a>
        <ul class='nav naf nav-second-level'>
          <li><a href='<?php echo site_url();?>m_pendidikan'>Pendidikan</a></li>
          <li><a href='<?php echo site_url();?>m_pekerjaan'>Pekerjaan</a></li>
          <li><a href='<?php echo site_url();?>m_th_ajaran'>Tahun Ajaran</a></li>
          <!-- <li><a href='<?php echo site_url();?>m_kelas'>Kelas</a></li> -->
          <li><a href='<?php echo site_url();?>m_jabatan'>Jabatan</a></li>
          <li><a href='<?php echo site_url();?>m_instansi'>Instansi</a></li>
        </ul>
      </li>
      <li class="<?php if ($charSDM =="m_tho" || $charSDM =="m_peg"){echo "active";}else{echo "";}?>"><a><i class="fa fa-file-text fa-fw"></i> SDM<span class='fa arrow'></span></a>
        <ul class='nav naf nav-second-level'>
          <li><a href='<?php echo site_url();?>m_pegawai'>Pegawai</a></li>
          <li><a href='<?php echo site_url();?>m_tholabah'>Tholabah</a></li>          
        </ul>
      </li>
      <li class="<?php if ($char =="a"){echo "active";}else{echo "";}?>"><a><i class="fa fa-cog fa-fw"></i> Pengaturan<span class='fa arrow'></span></a>
        <ul class='nav naf nav-second-level'>
          <li><a href='#'>Pengguna</a></li>
          <li><a href='<?php echo site_url();?>a_kelas'>Kelas</a></li>
          <li><a href='<?php echo site_url();?>a_sy'>Tagihan Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>a_non_sy'>Tagihan Non Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>a_subsidi'>Subsidi</a></li>
          <li><a href='<?php echo site_url();?>a_jabatan'>Jabatan</a></li>
        </ul>
      </li>
      <li class="<?php if ($char =="b"){echo "active";}else{echo "";}?>"><a><i class="fa fa-cogs fa-fw"></i> Pembagian<span class='fa arrow'></span></a>
        <ul class='nav naf nav-second-level'>
          <li><a href='<?php echo site_url();?>b_kelas'>Kelas</a></li>
          <li><a href='<?php echo site_url();?>b_non_sy'>Non Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>b_sub_sy'>Subsidi Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>b_sub_non_sy'>Subsidi Non Syahriyah</a></li>
        </ul>
      </li>
      <li><a><i class="fa fa-money fa-fw"></i> Transaksi<span class='fa arrow'></span></a>
        <ul class='nav naf nav-second-level'>
          <li><a href='<?php echo site_url();?>bayar_id'>Pembayaran</a></li>
        </ul>
      </li>
      <li><a><i class="fa fa-file-o"></i> Laporan<span class='fa arrow'></span></a>
        <ul class='nav naf nav-second-level'>
          <li><a href='<?php echo site_url();?>l_bayar_sy'>Pembayaran Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>l_bayar_nonsy'>Pembayaran Non Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>l_bagi_nonsy'>Pembagian Non Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>l_instansi'>Instansi Pemberi Subsidi</a></li>
          <li><a href='<?php echo site_url();?>l_subsidi_sy'>Subsidi Syahriyah</a></li>
          <li><a href='<?php echo site_url();?>l_subsidi_non_sy'>Subsidi Non Syahriyah</a></li>
        </ul>
      </li>
      
    </ul>
  </div>
</nav>

	
	<div id="page-wrap">
	<?php
		$this->load->view($main_view);
	?>		
	</div>

<div class="navbar navbar-default navbar-fixed-bottom barbawah">
  <div class="container-fluid">
    <div class="row">
      <div class="col-md-12">
      	<div class="barbawah-kiri">
      	&copy; elbayan.or.id
      	</div>
        <div class="col-md-6">
          <!-- Copyright&copy; 2014 Beattle of Surabaya Shop. All Rights Reserved -->
        </div>
        <div class="col-md-6 text-right text-kaki-kanan">
          <?php echo hijriah(date("Y-m-d"));?>
        </div>
      <div class="clearfix"></div>            
      </div>
    </div>
  <div class="clearfix"></div>
  </div>
  <div class="clearfix"></div>
</div> 

</div>	
  

	<script src="<?php echo base_url()?>content/theme/js/bootstrap.min.js"></script>
  <script src="<?php echo base_url()?>content/theme/js/plugins/zurb/foundation.min.js"></script>  
	<script src="<?php echo base_url()?>content/theme/js/plugins/zurb/foundation/foundation.reveal.js"></script>	
  <script src="<?php echo base_url()?>content/theme/js/plugins/metisMenu/jquery.metisMenu.js"></script> 
	<script src="<?php echo base_url()?>content/theme/js/plugins/price/price_format.2.0.min.js"></script>	
	<script src="<?php echo base_url()?>content/theme/js/elbayan.js"></script>
</body>

</html>